/*
 * Copyright (c) 2024 OpenValley(ShenZhen) Digital Industry Development Co., Ltd.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef VENDOR_APP_H_
#define VENDOR_APP_H_

#define TELINK_SDK_B91_BLE_MULTI 1
#ifdef __cplusplus
extern "C" {
#endif

/**
 * @brief Ensure that the device is Connected or Not. 
 * IS_CONNECT_FLAG = 1 Connected
 * IS_CONNECT_FLAG = 0 Not Connected
 */
extern int IS_CONNECT_FLAG;

/**
 * @brief		user initialization when MCU power on or wake_up from deepSleep mode
 * @param[in]	none
 * @return      none
 */
void UserInitNormal(void);

/**
 * @brief     Accessory Kit main loop
 * @param[in]  none.
 * @return     none.
 */
_attribute_no_inline_ void AcceKitMainLoop(void);

/**
 * Advertise data
*/
const unsigned char tbl_advData[] = {
    0x05, 0x09, 'e', 'O', 'B', 'U',
    0x02, 0x01, 0x05,                        // BLE limited discoverable mode and BR/EDR not supported
    0x03, 0x19, 0x80, 0x01,                  // 384, Generic Remote Control, Generic category
    0x05, 0x02, 0x12, 0x18, 0x0F, 0x18,      // incomplete list of service class UUIDs (0x1812, 0x180F)
};

/**
 * Scan response data
 * 0x08: data len
 * 0x09: data type
 */
const unsigned char tbl_scanRsp [] = {
    0x08, 0x09, 'O', 'B', 'U', 'D', 'e', 'm', 'o', 
};

#ifdef __cplusplus
}
#endif

#endif /* VENDOR_APP_H_ */
